class Solution(object):
    def largestTriangleArea(self, points):
        """
        :type points: List[List[int]]
        :rtype: float
        """

        def s(point1, point2, point3):
            return 0.5 * abs(
                    point1[0] * point2[1] + point2[0] * point3[1] + point3[0] * point1[1] - point1[0] * point3[1] -
                    point2[0] * point1[1] - point3[0] * point2[1])

        n = len(points)
        max_val = 0
        for i in range(n):
            for j in range(i + 1, n):
                for k in range(j + 1, n):
                    max_val = max(max_val, s(points[i], points[j], points[k]))
                    if i == 0 and j == 3 and k == 4:
                        s(points[i], points[j], points[k])

        return max_val


data = Solution()
points = [[0, 0], [0, 1], [1, 0], [0, 2], [2, 0]]
print(data.largestTriangleArea(points))
